1. Field of the Invention
The present invention relates to a workpiece surface inspecting method for detecting a defect in a surface such as a coated surface of a workpiece, and the degree of smoothness of the surface.
2. Description of the Background Art
A surface is inspected in the following manner. As shown in FIG. 1A, a workpiece surface 6 is irradiated via a convex lens 4 with light emitted from a projecting means 2 mounted to an arm or the like of an unillustrated robot. Then, the light is caused to converge on a detecting means 8 such as a CCD camera or the like. Further, an image 10a (see FIG. 1B) which has been detected by the detecting means 8, is subjected to image processing. Thereafter, the state of coating of the workpiece surface 6 is examined to thereby make a decision as to whether or not dust is being applied on the workpiece surface 6 and flaws exist thereon. In this case, an inspection region at which the workpiece surface 6 can be inspected at a time, can be enlarged by inspecting the workpiece surface 6 using the converged light.
In this case, the detected light satisfactorily falls on a light-receiving surface of the detecting means 8 if the workpiece surface 6 is planar. When, however, the workpiece surface 6 is curved as illustrated in FIG. 2A, the detected light is diffused from the workpiece surface 6. Therefore, a bright spot or area 12 (which is the effective inspection surface) and shadow areas 14 (which are unusable as an object to be inspected), are developed in a detected image 10b (see FIG. 2B). Further, a blurred portion is developed at the respective boundaries between the bright area 12 and each of the shadow areas 14. That is, small black spots or points (hereinafter called "isolated spots or points") tend to appear on the bright area 12 side due to the influence of the state of coating of the workpiece surface 6. Thus, when subsequent image processing is effected, the isolated points cannot be judged as being isolated points produced by the adhesion of dust, for example. Accordingly, each of the isolated points tends to be misjudged as being defects in coating. Therefore, there has been proposed a method of processing detected image data for dilation and erosion to thereby remove the isolated points from the image data.
When, however, all the detected image data are processed for dilation and erosion as described above, the time required to process the image is prolonged and the total inspection time is increased.
When the image processing is made on the entire surface of the detected image 10b, the image processing is performed even on the shadow area 14 in addition to the bright area 12, which is the effective inspection surface. Accordingly, the time required to inspect the workpiece surface is wasted and hence the entire inspection time is lengthened.
Further, such a conventional system has been disclosed in Japanese Laid-Open Patent Publication No. 1-180438, for example. According to the disclosure, a brightness/darkness-striped image projected on a surface to be inspected, is photographically recorded by an exposure means as a level signal indicative of strength and weakness of light. Then, the amount of light emitted from a light source is adjusted according to the strength of the level signal. The level signal can be detected within a predetermined range by adjusting the amount of the light emitted, irrespective of the difference in colors applied on the workpiece surface to be inspected and of any deterioration in the light source. Accordingly, any defect in the workpiece surface to be inspected can be reliably detected without a change in a predetermined defect criterion.
When the surface to be inspected is planar, defects in the surface can be satisfactorily detected once the amount of light is adjusted. The above conventional system is, however, accompanied by the problem that since the amount of light reflected by the surface to be inspected varies according to the state of exposure when the surface is curved, it is necessary to determine whether or not the level signal indicative of the strength and weakness of the light falls within a predetermined level range each time the surface to be inspected is photographically recorded and to repeatedly adjust the amount of the light accordingly. The total time required to inspect the surface is increased thereby.